package com.visizen.wisdomclass.server.client;

import com.visizen.wisdomclass.server.model.WcPublicscoreLog;
import com.visizen.wisdomclass.server.model.WcPublicscoreLogExample;
import java.util.List;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.DeleteProvider;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.InsertProvider;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Result;
import org.apache.ibatis.annotations.Results;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.SelectProvider;
import org.apache.ibatis.annotations.Update;
import org.apache.ibatis.annotations.UpdateProvider;
import org.apache.ibatis.type.JdbcType;

public interface WcPublicscoreLogMapper {
    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_publicscore_log
     *
     * @mbggenerated
     */
    @SelectProvider(type=WcPublicscoreLogSqlProvider.class, method="countByExample")
    int countByExample(WcPublicscoreLogExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_publicscore_log
     *
     * @mbggenerated
     */
    @DeleteProvider(type=WcPublicscoreLogSqlProvider.class, method="deleteByExample")
    int deleteByExample(WcPublicscoreLogExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_publicscore_log
     *
     * @mbggenerated
     */
    @Delete({
        "delete from wc_publicscore_log",
        "where log_id = #{log_id,jdbcType=BIGINT}"
    })
    int deleteByPrimaryKey(Long log_id);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_publicscore_log
     *
     * @mbggenerated
     */
    @Insert({
        "insert into wc_publicscore_log (log_id, user_id, ",
        "log_time, score, ",
        "score_remark)",
        "values (#{log_id,jdbcType=BIGINT}, #{user_id,jdbcType=BIGINT}, ",
        "#{log_time,jdbcType=TIMESTAMP}, #{score,jdbcType=INTEGER}, ",
        "#{score_remark,jdbcType=VARCHAR})"
    })
    int insert(WcPublicscoreLog record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_publicscore_log
     *
     * @mbggenerated
     */
    @InsertProvider(type=WcPublicscoreLogSqlProvider.class, method="insertSelective")
    int insertSelective(WcPublicscoreLog record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_publicscore_log
     *
     * @mbggenerated
     */
    @SelectProvider(type=WcPublicscoreLogSqlProvider.class, method="selectByExample")
    @Results({
        @Result(column="log_id", property="log_id", jdbcType=JdbcType.BIGINT, id=true),
        @Result(column="user_id", property="user_id", jdbcType=JdbcType.BIGINT),
        @Result(column="log_time", property="log_time", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="score", property="score", jdbcType=JdbcType.INTEGER),
        @Result(column="score_remark", property="score_remark", jdbcType=JdbcType.VARCHAR)
    })
    List<WcPublicscoreLog> selectByExample(WcPublicscoreLogExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_publicscore_log
     *
     * @mbggenerated
     */
    @Select({
        "select",
        "log_id, user_id, log_time, score, score_remark",
        "from wc_publicscore_log",
        "where log_id = #{log_id,jdbcType=BIGINT}"
    })
    @Results({
        @Result(column="log_id", property="log_id", jdbcType=JdbcType.BIGINT, id=true),
        @Result(column="user_id", property="user_id", jdbcType=JdbcType.BIGINT),
        @Result(column="log_time", property="log_time", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="score", property="score", jdbcType=JdbcType.INTEGER),
        @Result(column="score_remark", property="score_remark", jdbcType=JdbcType.VARCHAR)
    })
    WcPublicscoreLog selectByPrimaryKey(Long log_id);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_publicscore_log
     *
     * @mbggenerated
     */
    @UpdateProvider(type=WcPublicscoreLogSqlProvider.class, method="updateByExampleSelective")
    int updateByExampleSelective(@Param("record") WcPublicscoreLog record, @Param("example") WcPublicscoreLogExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_publicscore_log
     *
     * @mbggenerated
     */
    @UpdateProvider(type=WcPublicscoreLogSqlProvider.class, method="updateByExample")
    int updateByExample(@Param("record") WcPublicscoreLog record, @Param("example") WcPublicscoreLogExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_publicscore_log
     *
     * @mbggenerated
     */
    @UpdateProvider(type=WcPublicscoreLogSqlProvider.class, method="updateByPrimaryKeySelective")
    int updateByPrimaryKeySelective(WcPublicscoreLog record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table wc_publicscore_log
     *
     * @mbggenerated
     */
    @Update({
        "update wc_publicscore_log",
        "set user_id = #{user_id,jdbcType=BIGINT},",
          "log_time = #{log_time,jdbcType=TIMESTAMP},",
          "score = #{score,jdbcType=INTEGER},",
          "score_remark = #{score_remark,jdbcType=VARCHAR}",
        "where log_id = #{log_id,jdbcType=BIGINT}"
    })
    int updateByPrimaryKey(WcPublicscoreLog record);
}